<?php
	
	
	$id= $_GET['idbpos'];
				
	$cType = new CType ;
	
	$cCategory = new CCategory;
	
	$type= $cType -> CTypeDetail($id);
	
	$notification ="";
	if(isset($_GET['notification']))
	{
		$notification =constant($_GET['notification']);
	}
	
	if($type['status'] ==1)
		{
			$status ='Active';
		}
		else
		{
			$status ='Inactive	';
		}
	
	if(is_array($type))
	{
		$category = $cCategory -> CCategoryDetail($type['id_category']);
		
		$categoryName = "";
		if(is_array($category )	)
		{
			$categoryName = $category['name'];
		}
		else
		{
			$category = "Unknown Category";
		}
		
		
		$mainContent = '<form action="processType.php" method="post" name="form1">
				
						
				<div id="content2">				
					
					<span style="font-size:10px;color:#FF0000;font-weight:bold;font-family:Arial, Helvetica, sans-serif">'.$notification.'</span>
					
					<input type="hidden" name ="showType" value="'.$type['id'].'">
					<table border="0" width="90%" style="position:relative" align = "center" >
					<tr>
						<td align="left" valign="middle" height="50px"> 
						 <img src="images/profile.png" style="float:left" border="0"/>
						<span class="mystyle1"> Are you sure to delete this type </span>		 </td>
					</tr>
					<tr>
						<td>
						<span > Name : <b>'.$type['name'].'</b></span><br>
						
						<span class="mystyle2">Catergory: '.$categoryName.' <span><br>
						<span> Status : '.$status.'</span><br>
						<span> Having : [updating number of items....] items</span>
						</td>
						
					</tr>
					
					
					<tr align="center">
						<td height="50px">
							<input id="input2"  type="submit" name="btn_ok" value="  OK  ">
							<input id="input2" name="btn_cancel" type="submit" value="  Cancel  " >
						</td>
					</tr>

					</table>
				</div>
				<input type="hidden" name = "hTypeAction" value ="del">
				</form>';
		
		
		
	}
	
		

?>